import 'package:get/get.dart';
import 'package:note/routeConfig.dart';

import '../../common/tools.dart';
import '../../manager/global.dart';
import 'state.dart';

class SettingPageLogic extends GetxController {
  final SettingPageState state = SettingPageState();

  void onCleanAllNotes() {
    GlobalUtil.cleanNote();
  }

  void onCheckNewVersion() {
    Tools.checkVersion(showTrue: true);
  }

  void onSetApp() {
    Get.toNamed(RouteConfig.setAppPage);
  }

  void onSetLock() {
    Get.toNamed(RouteConfig.setLockPage);
  }
}
